A Best-Fitting B-Spline Neural Network Approach to the Prediction of Advection–Diffusion Physical Fields with Absorption and Source Terms

This paper proposed a two-dimensional steady-state field prediction approach that combines B-spline functions and a fully connected neural network. In this approach, field data, which are determined by corresponding control vectors, are fitted by a selected B-spline function set, yielding the corresponding best-fitting weight vectors, and then a fully connected neural network is trained using those weight vectors and control vectors. The trained neural network first predicts a weight vector using a given control vector, and then the corresponding field can be restored via the selected B-spline set. This method was applied to learn and predict two-dimensional steady advection–diffusion physical fields with absorption and source terms, and its accuracy and performance were tested and verified by a series of numerical experiments with different B-spline sets, boundary conditions, field gradients, and field states. The proposed method was finally compared with a generative adversarial network (GAN) and a physics-informed neural network (PINN). The results indicated that the B-spline neural network could predict the tested physical fields well; the overall error can be reduced by expanding the selected B-spline set. Compared with GAN and PINN, the proposed method also presented the advantages of a high prediction accuracy, less demand for training data, and high training efficiency.


Introduction
At present, industry and scientific research extensively involve various forms of physical fields and their computation and simulation, such as flow field, temperature field, etc.The traditional way, which applies various numerical methods to solve these complex mathematical models, usually encounters problems related to complex methods, poor convergence, and the high cost in terms of time, and presents poor adaptability, especially for systems with strong nonlinearity and whose model parameters are difficult to determine [1][2][3][4][5][6].In recent years, neural networks represented by deep learning have been successfully applied to the learning and prediction of many complex systems and scenarios, and applying machine learning to predict fields has become a hot topic [7][8][9].However, a field has the characteristics of continuous spatial distribution, and field prediction needs to consider each spatial point of the huge amount of field data rather than one or more individual features.If a traditional fully connected neural network is directly used to predict the field, the number of nodes in the network output layer will be very large, making network training extremely difficult.By selecting an appropriate set of basis functions, fitting the huge amount of field data as low-dimensional vectors, and then training an ordinary neural network on the low-dimensional data, a better neural network model can

Theory 2.1. Best-Fitting B-Spline Function
A one-dimensional B-spline function set with an order of k and an element number of m can be defined as follows: where {t j } is a knot sequence, {t j |j = 1, 2, . .., m + k + 1}.Assuming that x goes from x min to x max , the knot sequence for a uniform B-spline function can then be provided in ascending order as follows: Here, t j (j < k + 1 or j > m + 1) are external knots, t j (j > k + 1 or j < m + 1) are internal knots, and the other two are end knots.For a higher-dimension B-spline function, all the one-dimensional functions defined in each dimension need to be multiplied, as in Equation (1).Giving a two-dimensional function ϕ(x, y), we can have approximation ϕ*(x, y) composed of a linear combination of B-splines and a weight vectors a, as follows: Here, m x and m y are the numbers of B-spline functions in the x and y dimensions, respectively, and k x and k y are their corresponding orders.Rewriting this formula in terms of matrices, we have: and where N lj = N k x j (x)N k y l (y).In practice, function ϕ(x, y) is often given by n x × n y discrete points, ϕ(x i , y p ), for which we have a fitting error: Applying the least square method to minimize the fitting error E, we have a best-fitting weight vector a: Here and By using the best fitting, a function ϕ(x, y) or its discrete version ϕ*(x, y) can be represented by a weight vector and a pre-selected B-spline function set; as a consequence, a data set including amounts of ϕ*(x, y) can be degraded into a series of corresponding weight vectors along with a known B-spline function set.In general, the scale of ϕ*(x, y) is far greater than that of the corresponding weight vector, which is determined by the number of B-splines in the selected function set.Additionally, B-spline fitting can filter the high-frequency modes in ϕ*(x, y); the extent of this can be modified by changing the number or the order of the B-splines in the function set.Since the B-spline function is piecewise, the B-spline fitting can well approximate the high-frequency modes through the addition of more low-order B-splines to the function set instead of higher-order basis functions.

Combination of Neural Network and B-Spline Function
The architecture of the bBSNN is shown in Figure 1, which combines a fully connected neural network and the B-spline function fitting.A data set {OUT: ϕ(x, y)} with r samples along with r corresponding control vectors {IN: p} can be used as an example.
The training and prediction of this method can be illustrated as follows (Please refer to the Supplementary Materials for the bBSNN code.): (1) Use the numbers m x and m y and the orders k x and k y , and calculate the knot sequence in each dimension according to the domain boundaries of the data set, then generate the B-spline function set; (2) Calculate the best-fitting weight vector a using the least square method; thus, the data set can be replaced by: (3) Train an ordinary fully connected neural network whose input and output are now as follows: {In (4) Once the neural network is well trained, a new control vector p can be used to predict a new weight vector a; predicted function ϕ*(x, y) is then restored by Equation (3).

Numerical Experiments and Discussions
In this section, we focus on the numerical experiments conducted on general advection-diffusion physical fields, using absorption and source terms to examine the performance of the bBSNN, in which the boundary conditions and the scalar field are

Numerical Experiments and Discussions
In this section, we focus on the numerical experiments conducted on general advectiondiffusion physical fields, using absorption and source terms to examine the performance of the bBSNN, in which the boundary conditions and the scalar field are regarded as the input control vector {IN: p} and the output data {OUT: ϕ(x, y)}, respectively.Here, we consider the physical fields as follows: where ϕ is a scalar field and u is a vector field, such as the velocity field.a, b, c, and d are the coefficients of the diffusion, convection, absorption, and source terms, respectively.In the numerical experiments, a vortical velocity field with an average velocity of 1 is implanted into the PDE and expressed as follows: Here, L x and L y are the dimensions of the domain; u = u(x, y) and v = v(x, y) are the velocity components.The physical fields can be characterized by three parameters: (1) α = a/b, representing the diffusion rate of the scalar field; (2) Pécklet number Pe = LU/α, a dimensionless number representing the ratio of the convection intensity to the diffusion intensity of the scalar field; (3) My = L 2 C/a, a dimensionless number representing the ratio of the absorption intensity to the diffusion intensity of the scalar field.Here, L, U, and C are the characteristic length, velocity, and absorption rate of the system, respectively.(Please refer to the Supplementary Materials for the finite volume method calculation code of the above physical field.)

Numerical Experiment Setup and Preliminary Verification
For the numerical experiment setup, a square domain is configured for the physical fields, and two independent and variable conditions and two fixed conditions are set at the four boundaries of the domain for preliminary verification, as shown in Figure 2, yielding an input control vector p = [B 1 , B 2 ] T , whose values are slightly smoothed in the vicinity of their junction points by a hyperbolic tangent function.The parameters of the physical fields are given as a = 10, b = 200, and c = 0.5, d = 1000, which yields a field state with α = 0.05, Pe = 20, and My = 0.05.The numerical result of the scalar field ϕ(x, y) is obtained with a grid resolution of 128 × 128 using a finite volume method.The configuration of the B-spline function set is k x = k y = 2 and m x = m y = 10, determining a weight vector a with a size of 100 × 1.For the preliminary tests and verification, we generated a data se to train the neural network, where the input control vectors p were ra and B1, B2 ∈ [0, 100].By computing the DSSA physical fields corresponding field data ϕ(x, y) can be obtained, which yields 100 cor  For the preliminary tests and verification, we generated a data set with 100 samples to train the neural network, where the input control vectors p were randomly generated and B 1 , B 2 ∈ [0, 100].By computing the DSSA physical fields numerically, 100 corresponding field data ϕ(x, y) can be obtained, which yields 100 corresponding weight vectors a when using the best fit and the selected B-spline function set.Three hidden layers with 8, 10, and 12 nodes, respectively, and one output layer were configured for the fully connected neural network, while two S-shaped tangent functions and two pure linear functions were selected for the corresponding layers.After the network was trained, we verified the bBSNN method via predicting a case with [B 1 B 2 ] T = [80 50] T , which is a new sample that has not appeared in the training data set.Figure 3 shows the ground truth and predicted fields of this case, as well as the error between them.To evaluate the error field, we calculated the averaged value µ, standard deviation σ, and the averaged absolute error µ |ϕ*−ϕ| .When comparing Figure 3a with Figure 3b, they are shown to be extremely similar.Figure 3c shows the error field, and it can be seen that most of the errors are small, except those reaching about 10 at the corners or close to the boundaries.The average error µ = 0.0131, the standard deviation σ =1.4080, and the averaged absolute error µ |ϕ*−ϕ| = 0.6952.This quantitatively indicates that the agreement between the prediction and the ground truth is good.For the preliminary tests and verification, we generated a data set with 100 samples to train the neural network, where the input control vectors p were randomly generated and B1, B2 ∈ [0, 100].By computing the DSSA physical fields numerically, 100 corresponding field data ϕ(x, y) can be obtained, which yields 100 corresponding weight vectors a when using the best fit and the selected B-spline function set.Three hidden layers with 8, 10, and 12 nodes, respectively, and one output layer were configured for the fully connected neural network, while two S-shaped tangent functions and two pure linear functions were selected for the corresponding layers.After the network was trained, we verified the bBSNN method via predicting a case with [B1 B2] T = [80 50] T , which is a new sample that has not appeared in the training data set.Figure 3 shows the ground truth and predicted fields of this case, as well as the error between them.To evaluate the error field, we calculated the averaged value µ, standard deviation σ, and the averaged absolute error µ|ϕ*−ϕ|.When comparing Figure 3a with Figure 3b, they are shown to be extremely similar.Figure 3c shows the error field, and it can be seen that most of the errors are small, except those reaching about 10 at the corners or close to the boundaries.The average error µ = 0.0131, the standard deviation σ =1.4080, and the averaged absolute error µ|ϕ*−ϕ| = 0.6952.This quantitatively indicates that the agreement between the prediction and the ground truth is good.Qualitatively, it can be seen from Figure 3 that where the gradient is large, the error is likely to be large.To further reduce the error, we added more B-splines to the function Qualitatively, it can be seen from Figure 3 that where the gradient is large, the error is likely to be large.To further reduce the error, we added more B-splines to the function set to increase the resolution of the high-frequency components of the field when finding the best fitting.Figure 4a shows the prediction results when using the B-spline function set with k x = k y = 3 and m x = m y = 15.The error field in Figure 4b shows that the averaged error µ = −0.0012, the standard deviation σ = 0.3589, the averaged absolute error µ |ϕ*−ϕ| = 0.1160, and the maximum error is about 6.This indicates that the error can be greatly reduced by increasing the number of functions of the selected B-spline set.However, the computational cost and complexity of the training are also greatly increased.
the best fitting.Figure 4a shows the prediction results when using the B-spline function set with kx = ky = 3 and mx = my = 15.The error field in Figure 4b shows that the averaged error µ = −0.0012, the standard deviation σ =0.3589, the averaged absolute error µ|ϕ*−ϕ| = 0.1160, and the maximum error is about 6.This indicates that the error can be greatly reduced by increasing the number of functions of the selected B-spline set.However, the computational cost and complexity of the training are also greatly increased.

Effect of the Size of the Input Control Vectors
To examine the performance of the bBSNN method when predicting more complicated DSSA physical fields, we add more independent and variable boundary conditions to expand the size of the input control vectors.In this subsection, two numerical experiments are carried out, where the configuration of the selected B-spline function set is still so that kx = ky = 2 and mx = my = 10, while the independent and variable boundary conditions are increased to 4 and 6, respectively.The data sets of these two numerical experiments are given 150 and 200 random samples, respectively, with the control vector Bi ∈ [0, 100].For the architecture of the fully connected neural network, we only change the nodes of the input layer to match the size of the control vector and keep the hidden layers, the output layer, and the activation functions the same as those in Section 3.1.
Figure 5a shows the configuration of the numerical experiment with four independent boundary conditions, and the DSSA physical fields with the same parameters used in Section 3.1 were still computed at a grid resolution of 128 × 128, obtaining the ground-truth field under a tested condition [B1 B2 B3 B4] T = [80 50 25 60] T , as shown in Figure 5b.After the neural network was well trained, the predicted field obtained under the same conditions by the bBSNN is shown in Figure 5c, which is also very close to the ground-truth field.Figure 5d shows the error field, where µ = −0.0061,σ = 0.8270, µ|ϕ*−ϕ| = 0.3991, and the maximum error is about 12. Compared with the experiment with two independent boundary conditions, the characteristics of the error field are similar, while the error statistics are even smaller.This is likely due to the smaller field gradient under the tested condition.

Effect of the Size of the Input Control Vectors
To examine the performance of the bBSNN method when predicting more complicated DSSA physical fields, we add more independent and variable boundary conditions to expand the size of the input control vectors.In this subsection, two numerical experiments are carried out, where the configuration of the selected B-spline function set is still so that k x = k y = 2 and m x = m y = 10, while the independent and variable boundary conditions are increased to 4 and 6, respectively.The data sets of these two numerical experiments are given 150 and 200 random samples, respectively, with the control vector B i ∈ [0, 100].For the architecture of the fully connected neural network, we only change the nodes of the input layer to match the size of the control vector and keep the hidden layers, the output layer, and the activation functions the same as those in Section 3.1.
Figure 5a shows the configuration of the numerical experiment with four independent boundary conditions, and the DSSA physical fields with the same parameters used in Section 3.1 were still computed at a grid resolution of 128 × 128, obtaining the ground-truth field under a tested condition [B 1 B 2 B 3 B 4 ] T = [80 50 25 60] T , as shown in Figure 5b.After the neural network was well trained, the predicted field obtained under the same conditions by the bBSNN is shown in Figure 5c, which is also very close to the ground-truth field.Figure 5d shows the error field, where µ = −0.0061,σ = 0.8270, µ |ϕ*−ϕ| = 0.3991, and the maximum error is about 12. Compared with the experiment with two independent boundary conditions, the characteristics of the error field are similar, while the error statistics are even smaller.This is likely due to the smaller field gradient under the tested condition.
Similarly, Figure 6 shows the configuration of the numerical experiment with six independent boundary conditions and the ground-truth field, as well as that predicted under a tested boundary condition [B 1 B 2 B 3 B 4 B 5 B 6 ] T = [80 50 25 60 100 40] T .Figure 6d shows the error field, where µ = −0.0138,σ = 0.9471, µ |ϕ*−ϕ| = 0.4792.Compared with the experiment with four independent boundary conditions, the error slightly increases, while it is still less than that of the experiment with two.These numerical experiments indicate that the size of the input control vector has little effect on the accuracy of the bBSNN in predicting the steady-state DSSA physical fields, and the error variations are mainly due to the differences in the local field gradients.
while it is still less than that of the experiment with two.These numerical experiments indicate that the size of the input control vector has little effect on the accuracy of the bBSNN in predicting the steady-state DSSA physical fields, and the error variations are mainly due to the differences in the local field gradients.while it is still less than that of the experiment with two.These numerical experiments indicate that the size of the input control vector has little effect on the accuracy of the bBSNN in predicting the steady-state DSSA physical fields, and the error variations are mainly due to the differences in the local field gradients.

Effect of the Field Gradient
The aforementioned numerical experiments also imply a potential great influence from the field gradient on the accuracy of the bBSNN method.To further examine the effect of the field gradient, we change the value range of the boundary conditions to generate two data sets with greatly different field gradients in the physical fields with two independent boundary conditions, where B1, B2 ∈ [0, 300] and B1, B2 ∈ [0, 900], respectively.Additionally, the configuration of the domain, the selected B-spline function set (kx = ky = 3 and mx = my = 15), and the architecture of the fully connected neural network are the same as those used in the second test in Section 3.1.For these two data sets, we randomly generated 150 samples in their corresponding ranges.After these two networks were trained, the cases with conditions [B1 B2] T = [240 150] T and [720 450] T were predicted, respectively.Figure 7a-c

Effect of the Field Gradient
The aforementioned numerical experiments also imply a potential great influence from the field gradient on the accuracy of the bBSNN method.To further examine the effect of the field gradient, we change the value range of the boundary conditions to generate two data sets with greatly different field gradients in the physical fields with two independent boundary conditions, where B 1 , B 2 ∈ [0, 300] and B 1 , B 2 ∈ [0, 900], respectively.Additionally, the configuration of the domain, the selected B-spline function set (k x = k y = 3 and m x = m y = 15), and the architecture of the fully connected neural network are the same as those used in the second test in Section 3.1.For these two data sets, we randomly generated 150 samples in their corresponding ranges.After these two networks were trained, the cases with conditions [B 1 B 2 ] T = [240 150] T and [720 450] T were predicted, respectively.Figure 7a-c  = 0.0254, σ = 3.2288 and µ|ϕ*−ϕ| = 1.0429, and the maximum error is about 55.It can be seen that the error fields of these two cases are fairly similar except for their exact values.These results indicate that the prediction error of the bBSNN method is sensitive to the local field gradient.Specifically, comparing these two cases and the second case in Section 3.1, where B1, B2 ∈ [0, 100], we can further conclude that the error of the bBSNN when predicting the steady-state DSSA physical fields is approximately proportional to the field gradient.

Effect of the Field State
In this subsection, we further examine the performance of the bBSNN in predicting the physical fields with various field states, which are governed by the coefficients a, b, c, and d of Equation (13).Here, we carry out two representative numerical experiments: (1) a = 1, b = 1, c = 1, and d = 1, yielding the system parameters α = 1, Pe = 1, and My = 1; (2) a = 1, b = 100, c = 10, and d = 10, yielding the system parameters α = 0.01, Pe = 100, My = 10.The system parameters indicate that the conditions are moderate for the first experiment while they are much more severe for the second one.Specifically, the second experiment will suffer from a much lower diffusion rate alongside much stronger advection and absorption effects, resulting in much higher local field gradients.Additionally, the domain configuration, B-spline function set (kx = ky = 3 and mx = my = 15), and the architecture of the fully connected neural network are kept the same as those used in the second test in Section 3.1, where 100 samples are used for each data set to train the network.The tested conditions for these two numerical experiments are both [B1 B2] T = [80 50] T .Their ground-truth and predicted results, as well as the error fields, are shown in Figure 8.It can be seen that the pattern agreements between the predicted and the ground-truth fields for these two experiments are very good; however, the patterns of the error field are quite different, although the maximum errors are very close to each other.We calculated the error statistics for these: µ = 0.0069, σ = 0.2960, µ|ϕ*−ϕ| = 0.0781 for the first one and µ = 0.5788, σ = 1.0534, µ|ϕ*−ϕ| = 0.9219 for the second one.This indicates that the error ranges for these two experiments with different field states are similar, while the error statistics of the experiment with severe conditions are much larger than those of the one with moderate conditions.

Effect of the Field State
In this subsection, we further examine the performance of the bBSNN in predicting the physical fields with various field states, which are governed by the coefficients a, b, c, and d of Equation (13).Here, we carry out two representative numerical experiments: (1) a = 1, b = 1, c = 1, and d = 1, yielding the system parameters α = 1, Pe = 1, and My = 1; (2) a = 1, b = 100, c = 10, and d = 10, yielding the system parameters α = 0.01, Pe = 100, My = 10.The system parameters indicate that the conditions are moderate for the first experiment while they are much more severe for the second one.Specifically, the second experiment will suffer from a much lower diffusion rate alongside much stronger advection and absorption effects, resulting in much higher local field gradients.Additionally, the domain configuration, Bspline function set (k x = k y = 3 and m x = m y = 15), and the architecture of the fully connected neural network are kept the same as those used in the second test in Section 3.1, where 100 samples are used for each data set to train the network.The tested conditions for these two numerical experiments are both [B 1 B 2 ] T = [80 50] T .Their ground-truth and predicted results, as well as the error fields, are shown in Figure 8.It can be seen that the pattern agreements between the predicted and the ground-truth fields for these two experiments are very good; however, the patterns of the error field are quite different, although the maximum errors are very close to each other.We calculated the error statistics for these: µ = 0.0069, σ = 0.2960, µ |ϕ*−ϕ| = 0.0781 for the first one and µ = 0.5788, σ = 1.0534, µ |ϕ*−ϕ| = 0.9219 for the second one.This indicates that the error ranges for these two experiments with different field states are similar, while the error statistics of the experiment with severe conditions are much larger than those of the one with moderate conditions.

Comparison with Analytical Solutions
The general form of the two-dimensional diffusion equation is as follows: where Φ is the scalar field and D is the diffusion coefficient.If the above-mentioned diffusion equation has an analytical solution, it usually has specific boundary conditions and initial conditions.Therefore, we assume a case where there is an instantaneous point diffusion source in the region, as shown in Figure 3, and the initial conditions are as follows: Here, δ is the Dirichlet function.Under such conditions, there exists an analytical solution for Equation (15), as follows: Set D = 0.2, take the field distribution at t = 1 s as the target, take any point in the region shown in Figure 3 as the diffusion source, and record its coordinates (x0, y0) as the control

Comparison with Analytical Solutions
The general form of the two-dimensional diffusion equation is as follows: where Φ is the scalar field and D is the diffusion coefficient.If the above-mentioned diffusion equation has an analytical solution, it usually has specific boundary conditions and initial conditions.Therefore, we assume a case where there is an instantaneous point diffusion source in the region, as shown in Figure 3, and the initial conditions are as follows: Here, δ is the Dirichlet function.Under such conditions, there exists an analytical solution for Equation (15), as follows: Set D = 0.2, take the field distribution at t = 1 s as the target, take any point in the region shown in Figure 3 as the diffusion source, and record its coordinates (x 0 , y 0 ) as the control vector.Randomly generate 100 sets of control vectors and their corresponding field distributions as training data sets for the bBSNN, where the network structure and parameter settings are the same as in Section 3.1.Finally, the prediction effect is verified with the diffusion source coordinates of (0.7, 0.8) and the verification results are shown in Figure 9.
It can be seen from Figure 9a,b that the bBSNN prediction performance is good, the ground truth and prediction are extremely similar, and the error distribution is very average.The average error µ = 0.0187, the standard deviation σ = 0.0471, and the averaged absolute error µ |ϕ*−ϕ| = 0.0398.This shows that the bBSNN also shows great potential for predicting the diffusion field distribution with analytical solutions.
Entropy 2024, 26, x FOR PEER REVIEW 12 of 16 vector.Randomly generate 100 sets of control vectors and their corresponding field distributions as training data sets for the bBSNN, where the network structure and parameter settings are the same as in Section 3.1.Finally, the prediction effect is verified with the diffusion source coordinates of (0.7, 0.8) and the verification results are shown in Figure 9.It can be seen from Figure 9a,b that the bBSNN prediction performance is good, the ground truth and prediction are extremely similar, and the error distribution is very average.The average error µ = 0.0187, the standard deviation σ =0.0471, and the averaged absolute error µ|ϕ*−ϕ| = 0.0398.This shows that the bBSNN also shows great potential for predicting the diffusion field distribution with analytical solutions.

Method Comparision
To further demonstrate the effectiveness of bBSNN in predicting diffusion-advection-absorption-source physical fields, we compare it with GAN [18] and PINN [25].The network structure of GAN is set up as shown in Figure 10a, mainly comprising a generator and discriminator.The generator is composed of seven transposed convolutional layers, and the discriminator is composed of six convolutional layers and one fully connected layer.The network structure of PINN is shown in Figure 10b, where the loss function includes three parts: partial differential structure loss (PDE loss), boundary value condition loss (BC loss), and real data condition loss (data loss), and the hidden layer is composed of six fully connected layers.The numerical example presented in Section

Method Comparision
To further demonstrate the effectiveness of bBSNN in predicting diffusion-advectionabsorption-source physical fields, we compare it with GAN [18] and PINN [25].The network structure of GAN is set up as shown in Figure 10a, mainly comprising a generator and discriminator.The generator is composed of seven transposed convolutional layers, and the discriminator is composed of six convolutional layers and one fully connected layer.The network structure of PINN is shown in Figure 10b, where the loss function includes three parts: partial differential structure loss (PDE loss), boundary value condition loss (BC loss), and real data condition loss (data loss), and the hidden layer is composed of six fully connected layers.The numerical example presented in Section 3.1 is used to train the GAN and PINN, and the boundary condition of the test group is also set as [B 1 B 2 ] T = [80 50] T .vector.Randomly generate 100 sets of control vectors and their corresponding field distributions as training data sets for the bBSNN, where the network structure and parameter settings are the same as in Section 3.1.Finally, the prediction effect is verified with the diffusion source coordinates of (0.7, 0.8) and the verification results are shown in Figure 9.It can be seen from Figure 9a,b that the bBSNN prediction performance is good, the ground truth and prediction are extremely similar, and the error distribution is very average.The average error µ = 0.0187, the standard deviation σ =0.0471, and the averaged absolute error µ|ϕ*−ϕ| = 0.0398.This shows that the bBSNN also shows great potential for predicting the diffusion field distribution with analytical solutions.

Method Comparision
To further demonstrate the effectiveness of bBSNN in predicting diffusion-advection-absorption-source physical fields, we compare it with GAN [18] and PINN [25].The network structure of GAN is set up as shown in Figure 10a, mainly comprising a generator and discriminator.The generator is composed of seven transposed convolutional layers, and the discriminator is composed of six convolutional layers and one fully connected layer.The network structure of PINN is shown in Figure 10b, where the loss function includes three parts: partial differential structure loss (PDE loss), boundary value condition loss (BC loss), and real data condition loss (data loss), and the hidden layer is composed of six fully connected layers.The numerical example presented in Section  All the numerical cases were computed on PYTHON 3.6 with PYTORCH 1.10 and a computer with the configurations of Intel Xeon E5-2678@2.50GHz and an RAM of 128 GB.To compare the performances of the bBSNN, GAN, and PINN, we summarized the training (4) The data set used to train the bBSNN can be very small, even for the case with six independent boundary conditions, the bBSNN trained by a data set with only 200 random samples can yield a good predicted field, and the training efficiency is also very high.(5) Compared with GAN and PINN, bBSNN presents obvious advantages in terms of training efficiency and prediction accuracy.
Consequently, we believe the bBSNN method can be used as a good surrogate model to predict advection-diffusion physical fields under relatively complex conditions, and could also be used to accelerate the numerical computation of such physical fields.Although this work is carried out for steady-state advection-diffusion physical fields, the bBSNN method, if combined with a recurrent neural network, may have great potential to deal with transient physical fields, which could be our next step in the near future.

Figure 1 .
Figure 1.A schematic of the architecture of the best-fitting B−spline neural network.

Figure 1 .
Figure 1.A schematic of the architecture of the best-fitting B−spline neural network.

opy 2024 ,
26,  x FOR PEER REVIEW configuration of the B-spline function set is kx = ky = 2 and mx = my = weight vector a with a size of 100 × 1.

Figure 2 .
Figure 2. Configurations of the numerical experiments.

Figure 2 .
Figure 2. Configurations of the numerical experiments.

Figure 2 .
Figure 2. Configurations of the numerical experiments.

Figure 3 .
Figure 3. (a) Ground-truth steady-state field obtained by computing the DSSA physical fields using the finite volume method on a grid resolution of 128 × 128; (b) result predicted by the bBSNN with second-order 10 × 10 functions; (c) the error field between the ground truth and the prediction, where µ, σ, and µ|ϕ*−ϕ| are the averaged error, standard deviation, and the averaged absolute error, respectively.

Figure 3 .
Figure 3. (a) Ground-truth steady-state field obtained by computing the DSSA physical fields using the finite volume method on a grid resolution of 128 × 128; (b) result predicted by the bBSNN with second-order 10 × 10 functions; (c) the error field between the ground truth and the prediction, where µ, σ, and µ |ϕ*−ϕ| are the averaged error, standard deviation, and the averaged absolute error, respectively.

Figure 4 .
Figure 4. (a) The result predicted by the bBSNN with the second-order 15 × 15 functions and (b) the error field.

Figure 4 .
Figure 4. (a) The result predicted by the bBSNN with the second-order 15 × 15 functions and (b) the error field.

Figure 5 .
Figure 5. (a) The configuration of the numerical experiment with four independent boundary conditions, (b) the ground-truth field under the tested conditions [B1 B2 B3 B4] T = [80 50 25 60] T , (c) the predicted field, and (d) the error field of steady-state DSSA physical fields.

Figure 5 .
Figure 5. (a) The configuration of the numerical experiment with four independent boundary conditions, (b) the ground-truth field under the tested conditions [B 1 B 2 B 3 B 4 ] T = [80 50 25 60] T , (c) the predicted field, and (d) the error field of steady-state DSSA physical fields.

Figure 5 .Figure 6 .
Figure 5. (a) The configuration of the numerical experiment with four independent boundary conditions, (b) the ground-truth field under the tested conditions [B1 B2 B3 B4] T = [80 50 25 60] T , (c) the predicted field, and (d) the error field of steady-state DSSA physical fields.

Figure 6 .
Figure 6.(a) The configuration of the numerical experiment with six independent boundary conditions, (b) the ground-truth field under the tested conditions [B 1 B 2 B 3 B 4 B 5 B 6 ] T = [80 50 25 60 100 40] T , (c) the predicted field, and (d) the error field of a steady-state DSSA physical fields.
show the ground-truth field, predicted field, and the error field under the tested condition [B 1 B 2 ] T = [240 150] T , respectively, where µ = 0.0103, σ = 1.0766, and µ |ϕ*−ϕ| = 0.3525, and the maximum error is about 18. Figure 7d-f show the corresponding results under the tested conditions [B 1 B 2 ] T = [720 450] T , where µ = 0.0254, σ = 3.2288 and µ |ϕ*−ϕ| = 1.0429, and the maximum error is about 55.It can be seen that the error fields of these two cases are fairly similar except for their exact values.These results indicate that the prediction error of the bBSNN method is sensitive to the local field gradient.Specifically, comparing these two cases and the second case in Section 3.1, where B 1 , B 2 ∈ [0, 100], we can further conclude that the error of the bBSNN when predicting the steady-state DSSA physical fields is approximately proportional to the field gradient.

Figure 9 .
Figure 9. (a) Ground truth obtained by computing the diffusion fields using the analytical solutions; (b) the result predicted by the bBSNN with the third-order 15 × 15 functions; (c) the error field between the ground truth and the prediction, where µ, σ, and µ|ϕ*−ϕ| are the averaged error, standard deviation, and the averaged absolute error, respectively.

Figure 10 .
Figure 10.Schematics of the architectures of the used GAN and PINN.

Figure 9 .
Figure 9. (a) Ground truth obtained by computing the diffusion fields using the analytical solutions; (b) the result predicted by the bBSNN with the third-order 15 × 15 functions; (c) the error field between the ground truth and the prediction, where µ, σ, and µ |ϕ*−ϕ| are the averaged error, standard deviation, and the averaged absolute error, respectively.

Figure 9 .
Figure 9. (a) Ground truth obtained by computing the diffusion fields using the analytical solutions; (b) the result predicted by the bBSNN with the third-order 15 × 15 functions; (c) the error field between the ground truth and the prediction, where µ, σ, and µ|ϕ*−ϕ| are the averaged error, standard deviation, and the averaged absolute error, respectively.

Figure 10 .
Figure 10.Schematics of the architectures of the used GAN and PINN.Figure 10.Schematics of the architectures of the used GAN and PINN.

Figure 10 .
Figure 10.Schematics of the architectures of the used GAN and PINN.Figure 10.Schematics of the architectures of the used GAN and PINN.